import request from '@/utils/request';

export const getAllDepts = () => {
	return request({
		url: '/depts',
		method: 'get',
	});
}

export const addTenant = (data) => {
	return request({
		url: '/depts',
		method: 'post',
		data,
	});
}

export const updateDept = (id, data) => {
	return request({
		url: `/depts/${id}`,
		method: 'put',
		data,
	});
}

export const delTenant = (id) => {
	return request({
		url: `/depts/${id}`,
		method: 'delete',
	});
}